3.4 \(\int (d+i c d x) (a+b \tan ^{-1}(c x)) \, dx\)

Optimal. Leaf size=53 \[ -\frac{i d (1+i c x)^2 \left (a+b \tan ^{-1}(c x)\right )}{2 c}-\frac{b d \log (c x+i)}{c}-\frac{1}{2} i b d x \]

[Out]

(-I/2)*b*d*x - ((I/2)*d*(1 + I*c*x)^2*(a + b*ArcTan[c*x]))/c - (b*d*Log[I + c*x])/c

________________________________________________________________________________________

Rubi [A]  time = 0.0312274, antiderivative size = 53, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 3, integrand size = 18, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.167, Rules used = {4862, 627, 43} \[ -\frac{i d (1+i c x)^2 \left (a+b \tan ^{-1}(c x)\right )}{2 c}-\frac{b d \log (c x+i)}{c}-\frac{1}{2} i b d x \]

Antiderivative was successfully verified.

[In]

Int[(d + I*c*d*x)*(a + b*ArcTan[c*x]),x]

[Out]

(-I/2)*b*d*x - ((I/2)*d*(1 + I*c*x)^2*(a + b*ArcTan[c*x]))/c - (b*d*Log[I + c*x])/c

Rule 4862

Int[((a_.) + ArcTan[(c_.)*(x_)]*(b_.))*((d_) + (e_.)*(x_))^(q_.), x_Symbol] :> Simp[((d + e*x)^(q + 1)*(a + b*
ArcTan[c*x]))/(e*(q + 1)), x] - Dist[(b*c)/(e*(q + 1)), Int[(d + e*x)^(q + 1)/(1 + c^2*x^2), x], x] /; FreeQ[{
a, b, c, d, e, q}, x] && NeQ[q, -1]

Rule 627

Int[((d_) + (e_.)*(x_))^(m_.)*((a_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[(d + e*x)^(m + p)*(a/d + (c*x)/e)^
p, x] /; FreeQ[{a, c, d, e, m, p}, x] && EqQ[c*d^2 + a*e^2, 0] && (IntegerQ[p] || (GtQ[a, 0] && GtQ[d, 0] && I
ntegerQ[m + p]))

Rule 43

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d
*x)^n, x], x] /; FreeQ[{a, b, c, d, n}, x] && NeQ[b*c - a*d, 0] && IGtQ[m, 0] && ( !IntegerQ[n] || (EqQ[c, 0]
&& LeQ[7*m + 4*n + 4, 0]) || LtQ[9*m + 5*(n + 1), 0] || GtQ[m + n + 2, 0])

Rubi steps

\begin{align*} \int (d+i c d x) \left (a+b \tan ^{-1}(c x)\right ) \, dx &=-\frac{i d (1+i c x)^2 \left (a+b \tan ^{-1}(c x)\right )}{2 c}+\frac{(i b) \int \frac{(d+i c d x)^2}{1+c^2 x^2} \, dx}{2 d}\\ &=-\frac{i d (1+i c x)^2 \left (a+b \tan ^{-1}(c x)\right )}{2 c}+\frac{(i b) \int \frac{d+i c d x}{\frac{1}{d}-\frac{i c x}{d}} \, dx}{2 d}\\ &=-\frac{i d (1+i c x)^2 \left (a+b \tan ^{-1}(c x)\right )}{2 c}+\frac{(i b) \int \left (-d^2+\frac{2 i d^2}{i+c x}\right ) \, dx}{2 d}\\ &=-\frac{1}{2} i b d x-\frac{i d (1+i c x)^2 \left (a+b \tan ^{-1}(c x)\right )}{2 c}-\frac{b d \log (i+c x)}{c}\\ \end{align*}

Mathematica [A]  time = 0.0053182, size = 84, normalized size = 1.58 \[ \frac{1}{2} i a c d x^2+a d x-\frac{b d \log \left (c^2 x^2+1\right )}{2 c}+\frac{1}{2} i b c d x^2 \tan ^{-1}(c x)+b d x \tan ^{-1}(c x)+\frac{i b d \tan ^{-1}(c x)}{2 c}-\frac{1}{2} i b d x \]

Antiderivative was successfully verified.

[In]

Integrate[(d + I*c*d*x)*(a + b*ArcTan[c*x]),x]

[Out]

a*d*x - (I/2)*b*d*x + (I/2)*a*c*d*x^2 + ((I/2)*b*d*ArcTan[c*x])/c + b*d*x*ArcTan[c*x] + (I/2)*b*c*d*x^2*ArcTan
[c*x] - (b*d*Log[1 + c^2*x^2])/(2*c)

________________________________________________________________________________________

Maple [A]  time = 0.027, size = 71, normalized size = 1.3 \begin{align*} adx+{\frac{i}{2}}cda{x}^{2}+b\arctan \left ( cx \right ) xd+{\frac{i}{2}}cdb\arctan \left ( cx \right ){x}^{2}-{\frac{i}{2}}bdx-{\frac{db\ln \left ({c}^{2}{x}^{2}+1 \right ) }{2\,c}}+{\frac{{\frac{i}{2}}db\arctan \left ( cx \right ) }{c}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((d+I*c*d*x)*(a+b*arctan(c*x)),x)

[Out]

a*d*x+1/2*I*c*d*a*x^2+b*arctan(c*x)*x*d+1/2*I*c*d*b*arctan(c*x)*x^2-1/2*I*b*d*x-1/2*b*d*ln(c^2*x^2+1)/c+1/2*I/
c*d*b*arctan(c*x)

________________________________________________________________________________________

Maxima [A]  time = 1.47815, size = 99, normalized size = 1.87 \begin{align*} \frac{1}{2} i \, a c d x^{2} + \frac{1}{2} i \,{\left (x^{2} \arctan \left (c x\right ) - c{\left (\frac{x}{c^{2}} - \frac{\arctan \left (c x\right )}{c^{3}}\right )}\right )} b c d + a d x + \frac{{\left (2 \, c x \arctan \left (c x\right ) - \log \left (c^{2} x^{2} + 1\right )\right )} b d}{2 \, c} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((d+I*c*d*x)*(a+b*arctan(c*x)),x, algorithm="maxima")

[Out]

1/2*I*a*c*d*x^2 + 1/2*I*(x^2*arctan(c*x) - c*(x/c^2 - arctan(c*x)/c^3))*b*c*d + a*d*x + 1/2*(2*c*x*arctan(c*x)
 - log(c^2*x^2 + 1))*b*d/c

________________________________________________________________________________________

Fricas [B]  time = 2.8117, size = 204, normalized size = 3.85 \begin{align*} \frac{2 i \, a c^{2} d x^{2} + 2 \,{\left (2 \, a - i \, b\right )} c d x - 3 \, b d \log \left (\frac{c x + i}{c}\right ) - b d \log \left (\frac{c x - i}{c}\right ) -{\left (b c^{2} d x^{2} - 2 i \, b c d x\right )} \log \left (-\frac{c x + i}{c x - i}\right )}{4 \, c} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((d+I*c*d*x)*(a+b*arctan(c*x)),x, algorithm="fricas")

[Out]

1/4*(2*I*a*c^2*d*x^2 + 2*(2*a - I*b)*c*d*x - 3*b*d*log((c*x + I)/c) - b*d*log((c*x - I)/c) - (b*c^2*d*x^2 - 2*
I*b*c*d*x)*log(-(c*x + I)/(c*x - I)))/c

________________________________________________________________________________________

Sympy [B]  time = 1.68031, size = 102, normalized size = 1.92 \begin{align*} \frac{i a c d x^{2}}{2} + \frac{b d \left (- \frac{\log{\left (x - \frac{i}{c} \right )}}{4} - \frac{3 \log{\left (x + \frac{i}{c} \right )}}{4}\right )}{c} + x \left (a d - \frac{i b d}{2}\right ) + \left (- \frac{b c d x^{2}}{4} + \frac{i b d x}{2}\right ) \log{\left (- i c x + 1 \right )} + \left (\frac{b c d x^{2}}{4} - \frac{i b d x}{2}\right ) \log{\left (i c x + 1 \right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((d+I*c*d*x)*(a+b*atan(c*x)),x)

[Out]

I*a*c*d*x**2/2 + b*d*(-log(x - I/c)/4 - 3*log(x + I/c)/4)/c + x*(a*d - I*b*d/2) + (-b*c*d*x**2/4 + I*b*d*x/2)*
log(-I*c*x + 1) + (b*c*d*x**2/4 - I*b*d*x/2)*log(I*c*x + 1)

________________________________________________________________________________________

Giac [A]  time = 1.14796, size = 104, normalized size = 1.96 \begin{align*} \frac{2 \, b c^{2} d i x^{2} \arctan \left (c x\right ) + 2 \, a c^{2} d i x^{2} - 2 \, b c d i x + 4 \, b c d x \arctan \left (c x\right ) + 4 \, a c d x - 3 \, b d \log \left (c x + i\right ) - b d \log \left (c x - i\right )}{4 \, c} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((d+I*c*d*x)*(a+b*arctan(c*x)),x, algorithm="giac")

[Out]

1/4*(2*b*c^2*d*i*x^2*arctan(c*x) + 2*a*c^2*d*i*x^2 - 2*b*c*d*i*x + 4*b*c*d*x*arctan(c*x) + 4*a*c*d*x - 3*b*d*l
og(c*x + i) - b*d*log(c*x - i))/c